def reverse(ip):
    if ip=="":
        return ip
    else:
        return reverse(ip[1:])+ip[0]
ip=input("请输入一串字符：")
print(reverse(ip))